#ifndef UDPWORKER_H
#define UDPWORKER_H

#include <QRunnable>
#include <QThreadPool>
#include <QtNetwork>

class udpWorker : public QRunnable
{
public:
    explicit udpWorker(QUdpSocket* socket, const QHostAddress& sender, quint16 senderPort);
    void run();

private:
    QUdpSocket* socket;
    QHostAddress sender;
    quint16 senderPort;
    QByteArray datagram;
    bool m_bIsActive;

public:
    void stop();
};
#endif // SETDATETHREAD_H

